home *** CD-ROM | disk | FTP | other *** search
/ CD Ware Multimedia 1995 May / cd Ware (Juegos) Epimundo.iso / WIN / VB_SYS / PATCHVB.ZIP / README.TXT < prev   
Encoding:
Text File  |  1994-02-12  |  2.8 KB  |  78 lines

  1. PATCHVB
  2. -------
  3. By Rick Esterling, Copyright 1994, All Rights Reserved
  4.  
  5. PatchVB is FREEWARE.  You may modify and use it as you find fit, but it may
  6. not be resold or used in any way to make a profit.  If you do use it, some
  7. credit would be appreciated.  You are encouraged to send your
  8. comments/suggestions to:
  9.  
  10.   Rick Esterling
  11.   Three Cruse Alley
  12.   Huntsville, AL  35801
  13.   205-536-8568
  14.   
  15.   Internet: esterra@widget.msfc.nasa.gov
  16.        CIS: 73322,702 (I hang out in the MSBASIC forum daily)
  17.  
  18.  
  19. WHAT IT DOES
  20. ------------
  21. I've heard several people say that they don't like the default action that
  22. VB programs take when they are exectued from the DOS command line.  For
  23. those of you that have never tried it, VB programs don't just report "This
  24. program requires Microsoft Windows" and exit as do 99% of the other Windows
  25. programs.  Rather, it tries to invoke Windows and then exectutes your
  26. program at startup.  I personally prefer it to just respond as other
  27. Windows programs do, so I wrote this patch.
  28.  
  29.  
  30. HOW IT WORKS
  31. ------------
  32. PatchVB simply reads an EXE file and tries to determine whether or not the
  33. file is a Visual Basic program.  It does this by searching for the part of
  34. the stub in the EXE that files off Windows.  If it finds the stub, it
  35. simply renames the call to Win.com to an invalid filename (a backslant and
  36. two NUL characters (ASCII 255).  That way, when your VB EXE tries to launch
  37. Windows, it cannot find WIN.COM so it gracefully exits.
  38.  
  39.  
  40.  
  41. AN EXTRA TRICK
  42. --------------
  43. VB uses its own stub to create the stub of any EXEs that it compiles.  This
  44. means if you patch VB.EXE itself, then all the programs that you compile
  45. thereafter will automatically include this patch and will not need further
  46. attention.
  47.  
  48.  
  49.  
  50. DISCLAIMER
  51. ----------
  52. As is the case with any program that modifies your executable files, great
  53. caution should be used before you try PatchVB on any of your programs.
  54. ALWAYS MAKE BACKUPS BEFORE APPLYING THIS PATCH!  As you can see from the
  55. source code, PatchVB doesn't do anything "blindly".  It tries to convince
  56. itself as much as it can that it's about to do the right thing, but just in
  57. case, make a backup, ok?
  58.  
  59.  
  60.  
  61. FOR FUTURE REFERENCE
  62. --------------------
  63. If you use PatchVB on any of your programs and then decide later that you
  64. want to restore the original stub, you should be able to very easily
  65. reverse engineer PatchVB since the source code is included.  PatchVB itself
  66. can detect when a program has already had the patch applied, so all you
  67. would need to do is change that part to reinsert the correct filename that
  68. PatchVB originally renamed as described above.  If you can't get it going,
  69. let me know (via one of the addresses shown at the top of this document)
  70. and I will provide you with a program to restore the original stub.
  71.  
  72.  
  73.  
  74. Happy patching,
  75.  
  76. Rick Esterling
  77. 12 Feb 94
  78.